#include<stdio.h>
#include"authentification.h"
#include<string.h>
void saisir_code()
{
    int i=3;
    int res=0;
    char login_admin[]="admin";
    char login[6];
    char code_adm[]="password";
    char code[9];
    while((i!=0)&&(res==0))
    {
        printf("donner le login: ");
        scanf("%s",login);
        printf("donner le code: ");
        scanf("%s",code);

        if((strcmp (code,code_adm)==0)&&(strcmp (login,login_admin)==0))
        {
            res=1 ;
            printf("code correct \n");
        }
        else
        {
            i--;

            printf("ressayer: \n");
            printf("--------------------\n");

        }
    }
}

